﻿using System.Windows;
using System.Windows.Controls;
using corpus_platform.ViewModels;
using corpus_platform.Views;

namespace corpus_platform.Views.Control
{
    /// <summary>
    /// Interaction logic for MultipleFrameElementNode
    /// </summary>
    public partial class MultipleFrameElementNode : UserControl
    {
        public MultipleFrameElementNode()
        {
            InitializeComponent();
        }

        protected override void OnDrop(DragEventArgs e)
        {
            base.OnDrop(e);
            INodeStructure sourceNode = (INodeStructure)e.Data.GetData("Node");
            MultipleFrameElementViewModel targetNode = (MultipleFrameElementViewModel)this.DataContext;
            sourceNode.ChangeParentTo(targetNode);
            e.Handled = true;
        }
    }
}
